<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
$s_offet =0;
$q= $_GET["q"];
if(isset($_GET["s_offset"]))
$s_offet = $_GET["s_offset"];

$rdata = $cquery->searchAllContent($q, $offset, "no");

echo count($rdata);
for($i=0;$i<count($rdata);$i++)
{
    $link = "http://".$_SERVER["HTTP_HOST"].$rdata[$i]["url"];
    $s_div.="<div class='cat_list'>";
    $s_div.="<div class='ptitle'><h3><a href='".$link."' title='".$rdata[$i]["title"]."' >".$rdata[$i]["title"]."</h3></div>";
	if(strlen($rdata[$i]["picture"])>0){
	 $s_div.= "<img src=\"".$HOME_URL."resources/image.php?im=".$rdata[$i]["picture"]."&sz=100\"  class=\"imgleft\"/>";	
	}
   $s_div.=$rdata[$i]["text"];
     $s_div.= "<div class='redtxt'> URL : http://".$_SERVER["HTTP_HOST"].$rdata[$i]["url"]."</div>";
    $s_div.="</div>";
}
echo $s_div;

?>
